|
bldcfoc2 2.2.0
|
BLDC FOC 2 Click example. More...
Macros | |
| #define | BLDCFOC2_PROGRAM_EEPROM 0 |
Functions | |
| void | application_init (void) |
| void | application_task (void) |
| int | main (void) |
BLDC FOC 2 Click example.
This example demonstrates the control of a 3-phase brushless DC motor using the BLDC FOC 2 Click board. The motor speed is gradually increased and decreased while changing direction on each cycle. The example also includes an optional EEPROM programming step if enabled via macro.
The demo application is composed of two sections :
Initializes the logger and the Click board driver, applies the default configuration, and optionally programs the EEPROM if enabled.
Gradually ramps the motor speed up and down, applies brake and switches direction on each full speed cycle. Speed is controlled via PWM duty cycle.
BLDCFOC2_PROGRAM_EEPROM macro to 1 and ensure that the on-board PROG SEL switch is set to SCL/SDA during EEPROM programming, then returned to SPD/FGO before motor drive. The default EEPROM configuration is optimized for the motor F80 PRO KV1900, 11.2V 10A power supply and PWM input range 10-50% at 20kHz.| #define BLDCFOC2_PROGRAM_EEPROM 0 |
| void application_init | ( | void | ) |
< Logger config object.
< Click config object.
Logger initialization. Default baud rate: 115200 Default log level: LOG_LEVEL_DEBUG
| void application_task | ( | void | ) |
| int main | ( | void | ) |